package com.htfc786.reminder.service;

import com.htfc786.reminder.model.entity.Family;
import com.baomidou.mybatisplus.extension.service.IService;
import com.htfc786.reminder.model.entity.FamilyMember;

import java.util.List;

/**
* @author htfc786
* @description 针对表【family(家庭表)】的数据库操作Service
* @createDate 2024-10-03 21:39:53
*/
public interface FamilyService extends IService<Family> {

    Family createFamily(String name, Long creatorUserId);

    Family updateFamilyName(Long id, String name);

    Family getFamilyById(Long id);

    List<Family> searchFamiliesByName(String name);

    FamilyMember addFamilyMember(Long familyId, String name, Long userId, Boolean receiveLowStockNotifications, Boolean receiveUsageReminders);

    FamilyMember addFamilyMember(Long familyId, String name);

    int deleteFamilyMember(Long familyMemberId, Long currentUserId);

    FamilyMember updateFamilyMember(FamilyMember familyMember, Long currentUserId);

    List<FamilyMember> getAllFamilyMembers(Long familyId);
}
